package com.milo.sender;


import com.milo.common.MqDto;
import com.milo.common.RabbitMQService;
import com.milo.config.RabbitMQExchangeConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.*;

/**
 * 发送示例
 * @author Milo Lee
 * @date 2021-06-08 09:17
 */
@Slf4j
@Service
public class EvaluateSender{

    @Resource
    private RabbitMQService rabbitMQService;



    public void sendProjectInfo() throws Exception {

        MqDto<Object> mqDto=new MqDto<>();
        mqDto.setBusChannel("yunecai-exchange");
        mqDto.setExchange(RabbitMQExchangeConfig.TOPIC_EXCHANGE);
        mqDto.setRoutingKey("tenderStruct.project.evaluateInfo");
        mqDto.setMessageId(null);
        mqDto.setBody(null);
        rabbitMQService.convertAndSend(mqDto);
    }



}
